<?php /* Smarty version Smarty-3.1.18, created on 2017-05-17 08:15:38
         compiled from "/data/www/mystery/protected/modules/webadmin/views/group/list.tpl" */ ?>
<?php /*%%SmartyHeaderCode:26141776354cb08c372b7b9-94282638%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    '51171469dd085dfaa7be017bca8af7fc995fdc30' => 
    array (
      0 => '/data/www/mystery/protected/modules/webadmin/views/group/list.tpl',
      1 => 1494904920,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '26141776354cb08c372b7b9-94282638',
  'function' => 
  array (
  ),
  'version' => 'Smarty-3.1.18',
  'unifunc' => 'content_54cb08c37adb28_84245769',
  'variables' => 
  array (
    'group_name' => 0,
    'list' => 0,
    'val' => 0,
    'auth' => 0,
    'vv' => 0,
    'v' => 0,
    'page' => 0,
  ),
  'has_nocache_code' => false,
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_54cb08c37adb28_84245769')) {function content_54cb08c37adb28_84245769($_smarty_tpl) {?><?php if (!is_callable('smarty_modifier_date_format')) include '/data/www/mystery/protected/extensions/Smarty/plugins/modifier.date_format.php';
?><?php echo $_smarty_tpl->getSubTemplate ("../common/header.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array(), 0);?>

<table width="100%" border="0" cellspacing="0">
 <tr>
    <td width="13%" valign="top">
            <?php echo $_smarty_tpl->getSubTemplate ("../common/left.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array(), 0);?>

    </td>
    <td width="87%" valign="top">
        
        <table width="100%" border="0" cellspacing="0">
                <tr>
                <td>
                    <form name="form1" method="get" action="/webadmin/group/list">
                    <div class="subnav">
                        <div class="content-menu ib-a blue line-x">
                        <a href="#" class="on"><em>用户组管理</em></a><span>|</span><a href="/webadmin/group/add"><em>添加用户组</em></a>
                        <input type="text" value="<?php echo $_smarty_tpl->tpl_vars['group_name']->value;?>
" class="input-text" name="group_name" style="margin-left:30px;"><input type="submit" value="搜索" class="button" name="dosubmit">
                        <div class="clearbox"></div>  
                         </div>
                    </div>
                    </form>
              <div class="pad_10">
                <div class="table-list">
                <table width="100%">
                      <thead>
                        <tr>
                            <th>用户组名</th>
                            <th>用户组描述</th>
                            <th>具体权限</th>
                            <th>创建时间</th>
                            <th>操作</th>
                        </tr>
                      </thead>
                      <tbody>
                        <?php  $_smarty_tpl->tpl_vars['val'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['val']->_loop = false;
 $_smarty_tpl->tpl_vars['key'] = new Smarty_Variable;
 $_from = $_smarty_tpl->tpl_vars['list']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['val']->key => $_smarty_tpl->tpl_vars['val']->value) {
$_smarty_tpl->tpl_vars['val']->_loop = true;
 $_smarty_tpl->tpl_vars['key']->value = $_smarty_tpl->tpl_vars['val']->key;
?>
                        <?php if ($_smarty_tpl->tpl_vars['val']->value['group_id']!=1) {?>
                        <tr  onMouseOver="this.className='tr2'" onMouseOut="this.className='tr1'" class="tr1" id="group_<?php echo $_smarty_tpl->tpl_vars['val']->value['group_id'];?>
">
                            <td align="center"><?php echo $_smarty_tpl->tpl_vars['val']->value['group_name'];?>
</td>
                            <td align="center"><?php if ($_smarty_tpl->tpl_vars['val']->value['group_describe']) {?><?php echo $_smarty_tpl->tpl_vars['val']->value['group_describe'];?>
<?php } else { ?>无<?php }?></td>
                            <td style="width:50%">
                                <?php  $_smarty_tpl->tpl_vars['vv'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['vv']->_loop = false;
 $_smarty_tpl->tpl_vars['kk'] = new Smarty_Variable;
 $_from = $_smarty_tpl->tpl_vars['auth']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['vv']->key => $_smarty_tpl->tpl_vars['vv']->value) {
$_smarty_tpl->tpl_vars['vv']->_loop = true;
 $_smarty_tpl->tpl_vars['kk']->value = $_smarty_tpl->tpl_vars['vv']->key;
?>
                                    <?php if ($_smarty_tpl->tpl_vars['vv']->value['sub']) {?>
                                    <?php  $_smarty_tpl->tpl_vars['v'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['v']->_loop = false;
 $_smarty_tpl->tpl_vars['k'] = new Smarty_Variable;
 $_from = $_smarty_tpl->tpl_vars['vv']->value['sub']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['v']->key => $_smarty_tpl->tpl_vars['v']->value) {
$_smarty_tpl->tpl_vars['v']->_loop = true;
 $_smarty_tpl->tpl_vars['k']->value = $_smarty_tpl->tpl_vars['v']->key;
?>
                                        <?php if ($_smarty_tpl->tpl_vars['val']->value['group_auth']=='*'||check_auth($_smarty_tpl->tpl_vars['v']->value['action'],$_smarty_tpl->tpl_vars['val']->value['group_auth'])) {?><?php echo $_smarty_tpl->tpl_vars['v']->value['name'];?>
，<?php }?>
                                    <?php } ?>
                                    <?php }?>
                                <?php } ?>
                            </td>
                            <td align="center"><?php echo smarty_modifier_date_format($_smarty_tpl->tpl_vars['val']->value['create_time'],"%Y-%m-%d");?>
</td>
                            <td align="center">
                                <a href="/webadmin/user/list?group_id=<?php echo $_smarty_tpl->tpl_vars['val']->value['group_id'];?>
">成员管理</a> | 
                                <a href="/webadmin/group/edit?group_id=<?php echo $_smarty_tpl->tpl_vars['val']->value['group_id'];?>
">修改</a> | 
                                <a href="javascript:;" onclick='del(<?php echo $_smarty_tpl->tpl_vars['val']->value['group_id'];?>
)'>删除</a></td>
                        </tr>
                        <?php }?>
                        <?php } ?>
                         
                      </tbody>
                </table>
                        <div style="float:right;"><?php echo $_smarty_tpl->tpl_vars['page']->value;?>
</div>
                </div>
              </div>
    </td>
 </tr>
</table>
<script type="text/javascript">
    function del(group_id){
        if (confirm('确定删除？')) {
            $.getJSON('/webadmin/group/del',{group_id:group_id},function(res){
                if (res.status==1) {
                    $('#group_'+group_id).remove();
                }
                alert(res.note);
            });
        }
    }
    
</script>
<?php echo $_smarty_tpl->getSubTemplate ("../common/footer.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array(), 0);?>
<?php }} ?>
